FROM java:8

# 添加容器卷
VOLUME /tmp
VOLUME /log

# 将jar包添加到容器中并更名为app.jar
ADD nginx-test-0.0.1.jar app.jar

#暴露端口
EXPOSE 2020

# 设置时区 运行jar包
RUN /bin/cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime \
    && echo 'Asia/Shanghai' >/etc/timezone \
# 运行jar包
RUN bash -c 'touch /app.jar'
ENTRYPOINT ["java","-Djava.security.egd=file:/dev/./urandom","-jar","/app.jar"]
